package com.itboye.ihomebank.key;

import java.util.ArrayList;
import java.util.List;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.itboye.ihomebank.R;
import com.itboye.ihomebank.adapter.KaiSuoJiLuAdapter;
import com.itboye.ihomebank.base.BaseOtherActivity;
import com.itboye.ihomebank.bean.KaiSuoJiLuBean;
import com.itboye.ihomebank.custom.XListView;
/**
 * 开锁记录
 *
 */
public class ActivityKaiSuoJiLu extends BaseOtherActivity {
	
	KaiSuoJiLuAdapter adapter;
	
	XListView jilu_listview;
	
	ImageView key_title_finish;
	TextView key_title_title;
	RelativeLayout key_title_xuanze;
	TextView key_title_xuan;
	
	List<KaiSuoJiLuBean> list=new ArrayList<KaiSuoJiLuBean>();
	
	@Override
	public void onClick(View v) {
		switch (v.getId()) {
		case R.id.key_title_finish:
			finish();
			break;

		case R.id.key_title_xuanze://弹出框
			
			break;
		default:
			break;
		}

	}

	@Override
	protected int layout_id() {
		// TODO Auto-generated method stub
		return R.layout.activity_kaisuo_jilu;
	}

	@Override
	protected void onInitController() {
		adapter=new KaiSuoJiLuAdapter(this, list, R.layout.item_kaisuo_jilu);
		jilu_listview.setAdapter(adapter);
		
		for (int i = 0; i < 3; i++) {
			KaiSuoJiLuBean bean=new KaiSuoJiLuBean();
			bean.setName("1523850000"+i);
			
			list.add(bean);
		}
		
		adapter.notifyDataSetChanged();

	}

	@Override
	protected void onInit() {
		key_title_title.setText("开锁记录");
		key_title_xuan.setText("全部");
		
	}

	@Override
	protected void onReadIntent(Bundle bundle) {
		// TODO Auto-generated method stub

	}

}
